home *** CD-ROM | disk | FTP | other *** search
/ Clickx 44 / Clickx 44.iso / assets / swf / start.swf / scripts / __Packages / clickx / ui / UISoftwarePanel.as < prev   
Encoding:
Text File  |  2007-01-01  |  16.3 KB  |  385 lines

  1. var ┬º\x01┬º = 5;
  2. while(true)
  3. {
  4.    if(eval("\x01") == 5)
  5.    {
  6.       set("\x01",eval("\x01") + 858);
  7.       ┬º┬ºpush(true);
  8.    }
  9.    else if(eval("\x01") == 230)
  10.    {
  11.       set("\x01",eval("\x01") + 703);
  12.       if(┬º┬ºpop())
  13.       {
  14.          set("\x01",eval("\x01") - 695);
  15.       }
  16.    }
  17.    else if(eval("\x01") == 238)
  18.    {
  19.       set("\x01",eval("\x01") - 182);
  20.       ┬º┬ºpush(true);
  21.    }
  22.    else if(eval("\x01") == 56)
  23.    {
  24.       set("\x01",eval("\x01") + 530);
  25.       if(┬º┬ºpop())
  26.       {
  27.          set("\x01",eval("\x01") - 139);
  28.       }
  29.    }
  30.    else
  31.    {
  32.       if(eval("\x01") == 289)
  33.       {
  34.          break;
  35.       }
  36.       if(eval("\x01") == 205)
  37.       {
  38.          set("\x01",eval("\x01") + 194);
  39.          if(┬º┬ºpop())
  40.          {
  41.             set("\x01",eval("\x01") + 96);
  42.          }
  43.       }
  44.       else if(eval("\x01") == 945)
  45.       {
  46.          set("\x01",eval("\x01") - 715);
  47.          ┬º┬ºpush(true);
  48.       }
  49.       else if(eval("\x01") == 863)
  50.       {
  51.          set("\x01",eval("\x01") - 574);
  52.          if(┬º┬ºpop())
  53.          {
  54.             set("\x01",eval("\x01") + 656);
  55.          }
  56.       }
  57.       else if(eval("\x01") == 447)
  58.       {
  59.          set("\x01",eval("\x01") - 242);
  60.          ┬º┬ºpush(true);
  61.       }
  62.       else
  63.       {
  64.          if(eval("\x01") == 399)
  65.          {
  66.             set("\x01",eval("\x01") + 96);
  67.          }
  68.          else if(eval("\x01") == 586)
  69.          {
  70.             set("\x01",eval("\x01") - 139);
  71.             var _loc1_ = ┬º┬ºpop() + (┬º┬ºpop() + (┬º┬ºpop() eq ┬º┬ºpop()) + ┬º┬ºconstant(20));
  72.             _loc1_ += ┬º┬ºconstant(21);
  73.             eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(22)][┬º┬ºconstant(23)](_loc1_);
  74.             var _loc3_ = eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(22)][┬º┬ºconstant(24)]();
  75.             var _loc2_ = eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(22)][┬º┬ºconstant(25)](eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(9)]);
  76.             ┬º┬ºpop()[┬º┬ºpop()] = ┬º┬ºpop();
  77.             _loc2_[┬º┬ºconstant(26)] = function(theMessage)
  78.             {
  79.                eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(27)][┬º┬ºconstant(26)](theMessage);
  80.             };
  81.             _loc2_[┬º┬ºconstant(28)] = function(command)
  82.             {
  83.                eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(10)](command,eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(9)]);
  84.             };
  85.             _loc2_[┬º┬ºconstant(29)] = function()
  86.             {
  87.                eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(30)][┬º┬ºconstant(31)](eval(┬º┬ºconstant(7))[┬º┬ºconstant(8)][┬º┬ºconstant(9)]);
  88.             };
  89.             _loc1_[┬º┬ºconstant(32)] = function()
  90.             {
  91.                if(eval(┬º┬ºconstant(1))[┬º┬ºconstant(3)][┬º┬ºconstant(4)][┬º┬ºconstant(33)] == null)
  92.                {
  93.                   eval(┬º┬ºconstant(1))[┬º┬ºconstant(3)][┬º┬ºconstant(4)][┬º┬ºconstant(33)] = new eval(┬º┬ºconstant(1))[┬º┬ºconstant(3)][┬º┬ºconstant(4)]();
  94.                }
  95.                return eval(┬º┬ºconstant(1))[┬º┬ºconstant(3)][┬º┬ºconstant(4)][┬º┬ºconstant(33)];
  96.             };
  97.             ┬º┬ºconstant(34)(eval(┬º┬ºconstant(1))[┬º┬ºconstant(3)][┬º┬ºconstant(4)][┬º┬ºconstant(5)],null,1);
  98.          }
  99.          else if(eval("\x01") == 495)
  100.          {
  101.             set("\x01",eval("\x01") - 285);
  102.             if(!_global.clickx)
  103.             {
  104.                _global.clickx = new Object();
  105.             }
  106.             ┬º┬ºpop();
  107.             if(!_global.clickx.ui)
  108.             {
  109.                _global.clickx.ui = new Object();
  110.             }
  111.             ┬º┬ºpop();
  112.             if(!_global.clickx.ui.UISoftwarePanel)
  113.             {
  114.                clickx.ui.UISoftwarePanel = _loc1_ = function()
  115.                {
  116.                   super();
  117.                   mx.events.EventDispatcher.initialize(this);
  118.                };
  119.                clickx.ui.UISoftwarePanel extends MovieClip;
  120.                _loc2_ = _loc1_.prototype;
  121.                _loc2_.slideIn = function()
  122.                {
  123.                   var _loc2_ = (18 - this._x) / 2;
  124.                   if(Math.abs(_loc2_) < 0.2)
  125.                   {
  126.                      this._x = 18;
  127.                      if(this.validImage)
  128.                      {
  129.                         this.softImage_mc.image_mc.onEnterFrame = mx.utils.Delegate.create(this,this.handleImageLoading);
  130.                      }
  131.                      this.installBtn_mc._visible = true;
  132.                      this.installBtn_mc._alpha = 0;
  133.                      this.installBtn_mc.onEnterFrame = function()
  134.                      {
  135.                         this._alpha += 10;
  136.                         if(this._alpha >= 100)
  137.                         {
  138.                            delete this.onEnterFrame;
  139.                         }
  140.                      };
  141.                      delete this.onEnterFrame;
  142.                   }
  143.                   else
  144.                   {
  145.                      this._x += _loc2_;
  146.                   }
  147.                };
  148.                _loc2_.slideOut = function()
  149.                {
  150.                   var _loc2_ = (-235 - this._x) / 2;
  151.                   if(Math.abs(_loc2_) < 0.2)
  152.                   {
  153.                      this._x = -495;
  154.                      delete this.onEnterFrame;
  155.                      if(this.softToLoad_ID != "")
  156.                      {
  157.                         this.renderDetail(this.softToLoad_GID,this.softToLoad_ID);
  158.                         this.softToLoad_ID = "";
  159.                         this.softToLoad_GID = "";
  160.                         this.onEnterFrame = mx.utils.Delegate.create(this,this.slideIn);
  161.                      }
  162.                   }
  163.                   else
  164.                   {
  165.                      this._x += _loc2_;
  166.                   }
  167.                };
  168.                _loc2_.slideOutCB = function()
  169.                {
  170.                   var _loc2_ = (-235 - this._x) / 2;
  171.                   if(Math.abs(_loc2_) < 0.2)
  172.                   {
  173.                      this._x = -495;
  174.                      this.dispatchEvent({type:"onSoftwarePanelHidden"});
  175.                      delete this.onEnterFrame;
  176.                   }
  177.                   else
  178.                   {
  179.                      this._x += _loc2_;
  180.                   }
  181.                };
  182.                _loc2_.handleImageLoading = function()
  183.                {
  184.                   var _loc2_ = this.softImage_mc.image_mc.container_mc.getBytesLoaded() / this.softImage_mc.image_mc.container_mc.getBytesTotal() * 100;
  185.                   if(_loc2_ == 100)
  186.                   {
  187.                      this.softImage_mc.image_mc.onEnterFrame = mx.utils.Delegate.create(this,this.fadeInSoftImage);
  188.                   }
  189.                };
  190.                _loc2_.fadeInSoftImage = function()
  191.                {
  192.                   var _loc2_ = (- this.maskPosY) / 4;
  193.                   this.maskPosY += _loc2_;
  194.                   this.softImage_mc.mask_mc.clear();
  195.                   clickx.util.DrawingUtil.drawRectangle(this.softImage_mc.mask_mc,0,1,0,0,Math.round(this.maskPosY),200,109);
  196.                   if(this.maskPosY <= 0)
  197.                   {
  198.                      delete this.softImage_mc.image_mc.onEnterFrame;
  199.                   }
  200.                };
  201.                _loc2_.openLink = function()
  202.                {
  203.                   clickx.shell.Shell.getInstance().launchURL(this.link);
  204.                };
  205.                _loc2_.renderDetail = function(groupId, softId)
  206.                {
  207.                   this.installBtn_mc._visible = false;
  208.                   var _loc2_ = clickx.data.DataProvider.getInstance().getSoftware(groupId,softId);
  209.                   var _loc4_ = _loc2_.title;
  210.                   var _loc5_ = undefined;
  211.                   _loc5_ = this.titel_txt.getNewTextFormat();
  212.                   var _loc7_ = _loc5_.getTextExtent(_loc4_);
  213.                   this.titel_txt.autoSize = "left";
  214.                   this.titel_txt.text = _loc4_;
  215.                   this.type_txt.text = "Type: " + _loc2_.type;
  216.                   this.type_txt._y = this.titel_txt._y + this.titel_txt.textHeight + 5;
  217.                   this.prijs_txt._y = this.type_txt._y + 17;
  218.                   this.auteur_txt._y = this.prijs_txt._y + 17;
  219.                   this.platform_mc._y = this.auteur_txt._y + 16;
  220.                   this.platform_txt._y = this.auteur_txt._y + 22;
  221.                   this.content_txt._y = this.auteur_txt._y + 48;
  222.                   this.content_txt._height = 117 - (this.auteur_txt._y + 48 - 221);
  223.                   this.scroller_mc.scrollUp_mc._y = this.auteur_txt._y + 49 - 222;
  224.                   this.scroller_mc.slideArea_mc._y = this.scroller_mc.scrollUp_mc._y + 6;
  225.                   this.scroller_mc.slideArea_mc._height = 105 - (this.scroller_mc.scrollUp_mc._y - 1);
  226.                   this.scroller_mc.init(this.scroller_mc.scrollUp_mc._y + 19,91);
  227.                   this.prijs_txt.text = "Prijs: " + _loc2_.price;
  228.                   this.auteur_txt.text = "Auteur: " + _loc2_.author;
  229.                   this.platform_txt.text = _loc2_.platforms;
  230.                   this.content_txt.htmlText = _loc2_.text;
  231.                   this.content_txt.scroll = 0;
  232.                   if(this.content_txt.scroll < this.content_txt.maxscroll)
  233.                   {
  234.                      this.scroller_mc._visible = true;
  235.                   }
  236.                   else
  237.                   {
  238.                      this.scroller_mc._visible = false;
  239.                   }
  240.                   var _loc3_ = _loc2_.url;
  241.                   this.softwareLink = _loc2_.link;
  242.                   if(_loc3_.length > 45)
  243.                   {
  244.                      _loc3_ = _loc3_.substr(0,45) + "...";
  245.                   }
  246.                   this.link_txt.text = _loc3_;
  247.                   this.link_txt.autoSize = "left";
  248.                   this.link_btn.onPress = mx.utils.Delegate.create(this,this.openLink);
  249.                   this.link_btn._width = this.link_txt.textWidth;
  250.                   this.installBtn_mc.buttonText_txt.text = _loc2_.buttontext;
  251.                   this.link = _loc2_.url;
  252.                   this.linkType = _loc2_.buttontype;
  253.                   if(this.softImage_mc.image_mc != undefined)
  254.                   {
  255.                      this.softImage_mc.image_mc.removeMovieClip();
  256.                   }
  257.                   this.softImage_mc.createEmptyMovieClip("image_mc",1);
  258.                   this.softImage_mc.image_mc._y = 7;
  259.                   this.softImage_mc.image_mc.createEmptyMovieClip("container_mc",1);
  260.                   if(_loc2_.image != undefined && _loc2_.image != "undefined" && _loc2_.image != "")
  261.                   {
  262.                      if(clickx.util.PlatformUtil.getPlatform() == "pc")
  263.                      {
  264.                         this.softImage_mc.image_mc.container_mc.loadMovie(clickx.Application.getAppPath() + _loc2_.image);
  265.                      }
  266.                      else
  267.                      {
  268.                         this.softImage_mc.image_mc.container_mc.loadMovie(_loc2_.image);
  269.                      }
  270.                      this.validImage = true;
  271.                   }
  272.                   else
  273.                   {
  274.                      this.validImage = false;
  275.                   }
  276.                   this.softImage_mc.createEmptyMovieClip("mask_mc",2);
  277.                   this.maskPosY = 109;
  278.                   clickx.util.DrawingUtil.drawRectangle(this.softImage_mc.mask_mc,0,1,0,0,this.maskPosY,200,109);
  279.                   this.softImage_mc.image_mc.setMask(this.softImage_mc.mask_mc);
  280.                };
  281.                _loc2_.installSoftware = function()
  282.                {
  283.                   var _loc2_ = "";
  284.                   if(clickx.util.PlatformUtil.getPlatform() == "mac")
  285.                   {
  286.                      _loc2_ = clickx.Application.getAppPath(true) + "assets:software:";
  287.                   }
  288.                   else
  289.                   {
  290.                      _loc2_ = clickx.Application.getAppPath(true) + "assets\\software\\";
  291.                   }
  292.                   if(this.linkType == "url")
  293.                   {
  294.                      clickx.shell.Shell.getInstance().launchURL(this.softwareLink);
  295.                   }
  296.                   else if(this.linkType == "install")
  297.                   {
  298.                      clickx.shell.Shell.getInstance().launchFile(_loc2_ + this.softwareLink);
  299.                   }
  300.                   else
  301.                   {
  302.                      clickx.shell.Shell.getInstance().execute(_loc2_ + this.softwareLink);
  303.                   }
  304.                };
  305.                _loc2_.loadSoftwareInfo = function(groupId, softId)
  306.                {
  307.                   if(this._x > -495)
  308.                   {
  309.                      this.softToLoad_ID = softId;
  310.                      this.softToLoad_GID = groupId;
  311.                      this.installBtn_mc._visible = false;
  312.                      this.onEnterFrame = mx.utils.Delegate.create(this,this.slideOut);
  313.                   }
  314.                   else
  315.                   {
  316.                      this.renderDetail(groupId,softId);
  317.                      this.onEnterFrame = mx.utils.Delegate.create(this,this.slideIn);
  318.                   }
  319.                };
  320.                _loc2_.isOpen = function()
  321.                {
  322.                   return this._x <= -495 ? false : true;
  323.                };
  324.                _loc2_.slideOutAndDoCallBack = function()
  325.                {
  326.                   this.installBtn_mc._visible = false;
  327.                   this.onEnterFrame = mx.utils.Delegate.create(this,this.slideOutCB);
  328.                };
  329.                _loc2_.scrollTextTo = function(percent)
  330.                {
  331.                   this.content_txt.scroll = Math.round(this.content_txt.maxscroll / 100 * percent);
  332.                };
  333.                _loc2_.onLoad = function()
  334.                {
  335.                   this._x = -495;
  336.                   clickx.util.ButtonUtil.makeFrame_R_O_Effect(this.installBtn_mc,5);
  337.                   this.installBtn_mc.onPress = mx.utils.Delegate.create(this,this.installSoftware);
  338.                   this.installBtn_mc._visible = false;
  339.                   this.scroller_mc.addEventListener("onScrollBarChanged",this);
  340.                };
  341.                _loc2_.onScrollBarChanged = function(eventObject)
  342.                {
  343.                   this.scrollTextTo(eventObject.scrollTo);
  344.                };
  345.                _loc2_.softToLoad_ID = "";
  346.                _loc2_.softToLoad_GID = "";
  347.                _loc2_.maskPosY = 146;
  348.                _loc2_.link = "";
  349.                _loc2_.linkType = "";
  350.                _loc2_.validImage = false;
  351.                _loc2_.softwareLink = "";
  352.                ┬º┬ºpush(ASSetPropFlags(clickx.ui.UISoftwarePanel.prototype,null,1));
  353.             }
  354.             ┬º┬ºpop();
  355.          }
  356.          else if(eval("\x01") == 933)
  357.          {
  358.             set("\x01",eval("\x01") - 695);
  359.             ┬º┬ºpop() extends ┬º┬ºpop() instanceof ┬º┬ºpop() >>> ┬º┬ºpop();
  360.             ┬º┬ºpush(┬º┬ºpop() >>> ┬º┬ºpop());
  361.          }
  362.       }
  363.    }
  364. }
  365. set("\x01",eval("\x01") + 656);
  366. §§pop();
  367. ┬º┬ºpop()[┬º┬ºpop()] = ┬º┬ºpop()[┬º┬ºpop()][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][_loc3_][┬º┬ºconstant(24)][_loc4_][┬º┬ºconstant(24)][7][┬º┬ºconstant(24)][0][┬º┬ºconstant(36)];
  368. var _loc7_ = _loc1_[┬º┬ºconstant(23)][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][_loc3_][┬º┬ºconstant(24)][_loc4_][┬º┬ºconstant(24)][8][┬º┬ºconstant(24)][┬º┬ºconstant(25)];
  369. var _loc5_ = ┬º┬ºconstant(43);
  370. _loc2_ = 0;
  371. while(_loc2_ < _loc7_)
  372. {
  373.    _loc5_ += _loc1_[┬º┬ºconstant(23)][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][_loc3_][┬º┬ºconstant(24)][_loc4_][┬º┬ºconstant(24)][8][┬º┬ºconstant(24)][_loc2_][┬º┬ºconstant(26)][┬º┬ºconstant(44)];
  374.    if(_loc2_ != _loc7_ - 1)
  375.    {
  376.       _loc5_ += ┬º┬ºconstant(45);
  377.    }
  378.    _loc2_ = _loc2_ + 1;
  379. }
  380. _loc6_[┬º┬ºconstant(46)] = _loc5_;
  381. _loc6_[┬º┬ºconstant(47)] = _loc1_[┬º┬ºconstant(23)][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][_loc3_][┬º┬ºconstant(24)][_loc4_][┬º┬ºconstant(24)][9][┬º┬ºconstant(26)][┬º┬ºconstant(19)];
  382. _loc6_[┬º┬ºconstant(48)] = _loc1_[┬º┬ºconstant(23)][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][_loc3_][┬º┬ºconstant(24)][_loc4_][┬º┬ºconstant(24)][9][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][0][┬º┬ºconstant(36)];
  383. _loc6_[┬º┬ºconstant(49)] = _loc1_[┬º┬ºconstant(23)][┬º┬ºconstant(24)][0][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][_loc3_][┬º┬ºconstant(24)][_loc4_][┬º┬ºconstant(24)][9][┬º┬ºconstant(24)][1][┬º┬ºconstant(24)][0][┬º┬ºconstant(36)];
  384. return _loc6_;
  385.